<?php
use yii\helpers\Html;
use yii\bootstrap\ActiveForm;

/* @var $this yii\web\View */
/* @var $form yii\bootstrap\ActiveForm */
/* @var $model \mdm\admin\models\form\ChangePassword */

$this->title = Yii::t('rbac-admin', '修改真实姓名');
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="site-signup">
    <p>请输入真实姓名：</p>

    <div class="row">
        <div class="col-lg-5">
            <?php $form = ActiveForm::begin(['id' => 'form-change']); ?>
                <?= $form->field($model, 'realname')->textInput()->label('真实姓名') ?>
                <div class="form-group">
                    <?= Html::submitButton(Yii::t('rbac-admin', '修改'), ['class' => 'btn btn-primary', 'name' => 'change-button']) ?>
                </div>
            <?php ActiveForm::end(); ?>
        </div>
    </div>
</div>
<?php if( $force ){ ?>
<script>
    <?php $this->beginBlock('JS_NEW'); ?>
        var msg = '您尚未在系统中填写真实姓名，为了便于权限分配与管理，请先填写中文真实姓名，谢谢';
        alert(msg);
    <?php $this->endBlock(); ?>
    <?php $this->registerJs($this->blocks['JS_NEW'], \yii\web\View::POS_END); ?>
</script>
<?php } ?>
